import Vue from 'vue'
import Router from 'vue-router'
import movieList from '@/components/movieList'
import MovieDetail from '@/components/MovieDetail'
import comments from '@/components/comments'
import casts from '@/components/casts'
import search from '@/components/search'

Vue.use(Router)

export default new Router({
  routes: [
    {
      	path: '/',
      	name: 'movieList',
      	component: movieList
    },
    {
      path:'/search',
      name:'search',
      component:search
    },
    {
    	path:'/movie/:id',
    	name:'MovieDetail',
    	component:MovieDetail
    },
    {
      path:'/movie/:id/comments',
      name:'comments',
      component:comments
    },
    {
      path:'/casts/:id',
      name:'casts',
      component:casts
    }
  ]
})
